<ion-view view-title="商品分类" show-tabs>
    <ion-nav-buttons side="right">
      <button class="button button-icon ion-android-add" ng-click="openModal()"></button>
    </ion-nav-buttons>
	<ion-content>
		<tree-view
			recursion-template='templates/common/model/list-tree.html',
			tree-data="myCataTree" 
			text-field="name" 
			leaf-icon="ion-link" 
			pre-href="product-catalog" 
			value-field='_id'
			item-clicked="itemClicked($item)" 
			item-checked-changed="itemCheckedChanged($item)" 
			expend-all="expendAll(treeData)" 
			can-checked="true">
		</tree-view>

	    <ion-list>
			<ion-item class="text-center" ng-if="!myCataTree.length">
	    		<span ng-if="true">暂无分类</span>
	    	</ion-item>
	    	
			<ion-item class="margin-top-large item-icon-left item-icon-right" href="#/default-product-catalogs">
				<i class="icon ion-fork-repo royal"></i>
				启用默认分类
				<i class="dark2 icon ion-ios-arrow-right"></i>
			</ion-item>
			<ion-item class="item-icon-left" ng-click="openModal()">
				<i class="icon ion-plus royal"></i>
				添加分类
			</ion-item>
	    </ion-list>
	</ion-content>
</ion-view>

